package org.pku_uestc.hackathon.utils;

import android.os.Build;

public class DeviceUtils {
	
	public static final int ANDROID_SDK_VERSION = Build.VERSION.SDK_INT;
	
	/**
     * if android sdk is 4.1
     * @return
     */
    public static boolean isApiLevel16() {
        return ANDROID_SDK_VERSION >= 16;
    }

    public static boolean isIceCreamSandwich() {
        return ANDROID_SDK_VERSION >= 14;
    }

    public static boolean isHoneycomb() {
        return ANDROID_SDK_VERSION >= 11 && ANDROID_SDK_VERSION < 14;
    }
    
    public static boolean isUnstabitilyAccelerateSdk() {
        return ANDROID_SDK_VERSION >= 11 && ANDROID_SDK_VERSION < 16;
    }

    /**
     * if android sdk is 2.2
     *
     * @return
     */
    public static boolean isFroyo() {
        return ANDROID_SDK_VERSION == 8;
    }

    /**
     * if android sdk is 2.1
     *
     * @return
     */
    public static boolean isEclair() {
        return ANDROID_SDK_VERSION == 7;
    }
}
